find_path(GOOGLETEST_INCLUDE_DIRS gtest/gtest.h gmock/gmock.h)

find_library(GOOGLETEST_GTEST_LIBRARIES gtest)
find_library(GOOGLETEST_GTEST_MAIN_LIBRARIES gtest_main)
find_library(GOOGLETEST_GMOCK_LIBRARIES gmock)

set(GOOGLETEST_LIBRARIES
        ${GOOGLETEST_GTEST_LIBRARIES}
        ${GOOGLETEST_GMOCK_LIBRARIES}
)

find_package_handle_standard_args(googletest DEFAULT_MSG GOOGLETEST_LIBRARIES GOOGLETEST_INCLUDE_DIRS)

mark_as_advanced(GOOGLETEST_INCLUDE_DIRS GOOGLETEST_LIBRARIES)